package chamster.actions;

import chamster.BaseHamster;

public class MoveLeftAction<HamsterType extends BaseHamster>
	implements HamsterAction<HamsterType> {

	public boolean isApplicable(HamsterType hamster) throws Exception {
		return hamster.getView().canMoveLeft() && hamster.chargeLeft(3);
	}

	public void run(HamsterType hamster) throws Exception {
		hamster.turnLeft();
		hamster.foreward();
		hamster.turnRight();
	}

}
